package january;

public class TestMain {
    public static void main(String[] args) {
        int h = 0;
        for(int i = 0; i <= 26; i++) {
            double m = Math.pow(16,i);
            h += m*10;
            if(h > 2022) {
                System.out.println(h);
                return;
            }
        }
    }
}
